<script>
/*
  创建一个```Employee```（员工）类
实现以下要求：

- 构造方法有两个参数，firstname（名），lastname（姓），都是英文，并初始化相应的属性
- 员工有属性fullname（全名）和email
  - fullname 是姓 名
  - email的值是姓.名@company.com
*/

class Employee {
	constructor (firstname, lastname) {
		this.firstname = firstname
		this.lastname = lastname
	}
	get fullname() { return this.lastname + ' ' + this.firstname}
	get email() { return `${this.lastname}.${this.firstname}@company.com`}
}


emp1 = Employee("Zhang", "San")
emp1.fullname // "Zhang San"
emp1.fullname = '123' // 赋值无效
emp1.fullname // 还是"Zhang San"

emp2 = Employee("Li",  "Si")
emp2.email // "li.si@company.com"

</script>